package com.ronri.ams.bean;

import com.ronri.common.StringManager;

import java.util.List;

/**
 * 文件：ams.java
 * 包名：com.ronri.ams.bean;
 * 说明：
 * 作者：MS During
 * 日期：2017/5/18
 * 历史：
 */
public class projectListbean {


    /**
     * code : 0
     * data : {"page":1,"pageSize":5,"records":4,"rowBegin":1,"rowEnd":5,"rows":[{"project_id":54,"plan_id":14,"lead_id":174,"dept_type":1,"name":"2017第三季度例行监测【定性】","nature":1,"start_date":"2017-05-01 00:00:00","end_date":"2017-06-10 00:00:00","publish_time":"2017-05-14 21:25:06","nature_name":"定性","dept_name":"常州市农畜水产品质量监督检验测试中心"},{"project_id":55,"plan_id":14,"lead_id":174,"dept_type":1,"name":"2017第三季度例行监测【定量】","nature":2,"start_date":"2017-05-01 00:00:00","end_date":"2017-05-27 00:00:00","publish_time":"2017-05-14 21:25:02","nature_name":"定量","dept_name":"常州市农畜水产品质量监督检验测试中心"}],"total":1}
     * message : success
     * success : true
     */

    private int code;
    private DataBean data;
    private String message;
    private boolean success;

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public DataBean getData() {
        return data;
    }

    public void setData(DataBean data) {
        this.data = data;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public boolean isSuccess() {
        return success;
    }

    public void setSuccess(boolean success) {
        this.success = success;
    }

    public static class DataBean {
        /**
         * page : 1
         * pageSize : 5
         * records : 4
         * rowBegin : 1
         * rowEnd : 5
         * rows : [{"project_id":54,"plan_id":14,"lead_id":174,"dept_type":1,"name":"2017第三季度例行监测【定性】","nature":1,"start_date":"2017-05-01 00:00:00","end_date":"2017-06-10 00:00:00","publish_time":"2017-05-14 21:25:06","nature_name":"定性","dept_name":"常州市农畜水产品质量监督检验测试中心"},{"project_id":55,"plan_id":14,"lead_id":174,"dept_type":1,"name":"2017第三季度例行监测【定量】","nature":2,"start_date":"2017-05-01 00:00:00","end_date":"2017-05-27 00:00:00","publish_time":"2017-05-14 21:25:02","nature_name":"定量","dept_name":"常州市农畜水产品质量监督检验测试中心"}]
         * total : 1
         */

        private int page;
        private int pageSize;
        private int records;
        private int rowBegin;
        private int rowEnd;
        private int total;
        private List<RowsBean> rows;

        public int getPage() {
            return page;
        }

        public void setPage(int page) {
            this.page = page;
        }

        public int getPageSize() {
            return pageSize;
        }

        public void setPageSize(int pageSize) {
            this.pageSize = pageSize;
        }

        public int getRecords() {
            return records;
        }

        public void setRecords(int records) {
            this.records = records;
        }

        public int getRowBegin() {
            return rowBegin;
        }

        public void setRowBegin(int rowBegin) {
            this.rowBegin = rowBegin;
        }

        public int getRowEnd() {
            return rowEnd;
        }

        public void setRowEnd(int rowEnd) {
            this.rowEnd = rowEnd;
        }

        public int getTotal() {
            return total;
        }

        public void setTotal(int total) {
            this.total = total;
        }

        public List<RowsBean> getRows() {
            return rows;
        }

        public void setRows(List<RowsBean> rows) {
            this.rows = rows;
        }

        public static class RowsBean {
            /**
             * project_id : 54
             * plan_id : 14
             * lead_id : 174
             * dept_type : 1
             * name : 2017第三季度例行监测【定性】
             * nature : 1
             * start_date : 2017-05-01 00:00:00
             * end_date : 2017-06-10 00:00:00
             * publish_time : 2017-05-14 21:25:06
             * nature_name : 定性
             * dept_name : 常州市农畜水产品质量监督检验测试中心
             */

            private int project_id;
            private int plan_id;
            private int lead_id;
            private int dept_type;
            private String name;
            private int nature;
            private String start_date;
            private String end_date;
            private String publish_time;
            private String nature_name;
            private String dept_name;

            public int getProject_id() {
                return project_id;
            }

            public void setProject_id(int project_id) {
                this.project_id = project_id;
            }

            public int getPlan_id() {
                return plan_id;
            }

            public void setPlan_id(int plan_id) {
                this.plan_id = plan_id;
            }

            public int getLead_id() {
                return lead_id;
            }

            public void setLead_id(int lead_id) {
                this.lead_id = lead_id;
            }

            public int getDept_type() {
                return dept_type;
            }

            public void setDept_type(int dept_type) {
                this.dept_type = dept_type;
            }

            public String getName() {
                return name;
            }

            public void setName(String name) {
                this.name = name;
            }

            public int getNature() {
                return nature;
            }

            public void setNature(int nature) {
                this.nature = nature;
            }

            public String getStart_date() {
                if( StringManager.InitString(start_date).length() > 10 )
                    return start_date.substring(0,10);
                else
                    return start_date;
            }

            public void setStart_date(String start_date) {
                this.start_date = start_date;
            }

            public String getEnd_date() {
                return end_date;
            }

            public void setEnd_date(String end_date) {
                this.end_date = end_date;
            }

            public String getPublish_time() {
                return publish_time;
            }

            public void setPublish_time(String publish_time) {
                this.publish_time = publish_time;
            }

            public String getNature_name() {
                return nature_name;
            }

            public void setNature_name(String nature_name) {
                this.nature_name = nature_name;
            }

            public String getDept_name() {
                return dept_name;
            }

            public void setDept_name(String dept_name) {
                this.dept_name = dept_name;
            }
        }
    }
}
